package com.agentai.framework.satoken.constant;

/**
 * @Author fuzhilin
 * @Date 2023/2/18 0018 11:36
 * @Description 互联网专项常量
 */
public class SaConstants {

    /**
     * 在线用户类型 redis key
     */
    public static final String APP = "app:";
    public static final String MP = "mp:";
    public static final String ADMIN = "admin:";

    /**
     * loginid构造拼接字符串
     */
    public static final String LOGINID_JOIN_CODE = ":";

    /**
     * 在线用户 redis key
     */
    public static final String ONLINE_TOKEN_KEY = "online_tokens:";
    /**
     * 登录用户 redis key
     */
    public static final String LOGIN_TOKEN_KEY = "Authorization:login:token:";

    /**
     * 防重提交 redis key
     */
    public static final String REPEAT_SUBMIT_KEY = "repeat_submit:";

    /**
     * 限流 redis key
     */
    public static final String RATE_LIMIT_KEY = "rate_limit:";


    /**
     * 上传图片文件格式白名单
     */
    public static final String FILE_FORMAT_WHITE = "bmp,jpg,png,tif,gif,pcx,tga,exif,fpx,svg,psd,cdr,pcd,dxf,ufo,eps,ai,raw,WMF,webp,avif,apng,jpeg," +
            "BMP,JPG,PNG,TIF,GIF,PCX,TGA,EXIF,FPX,SVG,PSD,CDR,PCD,DXF,UFO,EPS,AI,RAW,WMF,WEBP,AVIF,APNG,JPEG,";

    /**
     * 管理端请求前缀
     */
    public static final String ADMIN_CONTEXT_PATH = "/health-admin";

    /**
     * 小程序请求前缀
     */
    public static final String MP_CONTEXT_PATH = "/health-app";

    /**
     * 健康师端请求前缀
     */
    public static final String MANAGER_CONTEXT_PATH = "/health-manager";

}
